<template>
    <div class="news">
        <h1>{{ decData.title }}</h1>
        <div style="height:20px"></div>
        <div v-html="decData.content"></div>
    </div>
</template>

<script>
export default {
    data() {
        return {
            decData: {},
            prefixUrl: "",
        };
    },
    created() {
        this.prefixUrl = this.$store.state.user.imgUrl;
        this.getGygxList();
    },
    methods: {
        async getGygxList() {
            const res = await this.$store.dispatch("news/getGygxList");
            this.decData = res.page.list[0];
            console.log(res.page.list[0]);
        },
    },
};
</script>

<style scoped>
.news {
    margin: 20px 0;
}
.news > h1 {
    text-align: center;
    font-size: 24px;
    color: #000;
    font-weight: 500;
}
.news a {
    background-color: #371f75;
    color: #fff;
    padding: 10px 20px;
    border-radius: 5px;
}
.news span {
    display: flex;
    justify-content: flex-end;
    padding: 20px 30px;
    font-size: 14px;
}
.news >>> table {
    border: 1px solid #e0e0e0 !important;
    text-align: center;
}
.news >>> table tr {
    border-right: 1px solid #e0e0e0 !important;
    border-bottom: 1px solid #e0e0e0 !important;
    border-top: 1px solid #e0e0e0 !important;
}
.news >>> table td {
    /* flex: 1; */
    padding: 5px;
    border-left: 1px solid #e0e0e0;
    border-bottom: 1px solid #e0e0e0 !important;
    word-break: break-all;
}
</style>
